<script language="javascript" type="text/javascript" src="<?php echo base_url(); ?>js/jQuery1.7.2.js"></script>
<script language="javascript">
	var jq = jQuery.noConflict();
	jq(document).ready(function(){
		jq("#country").change(function(){		
			var a_city 	= jq("a.hidden-city").attr("href");
			
			var val		= {'cid' : jq(this).val() };
			jq.post(a_city, val, function(data){
				parse_city_data(data);
			});
		});
		
		function parse_city_data(data){
			alert(data);
		}
	});
</script>
<div>
	<div style="float:left;width:200px;">
		<?php if(count($country)): ?>
		<h3>Country list</h3>
			<select name="country" size="30" id="country">
				<?php foreach($country as $v): ?>
					<option value="<?php echo $v['iso']; ?>"><?php echo $v['name']; ?></option>
				<?php endforeach; ?>
			</select>
		<?php endif; ?>
	</div>
	<div style="float:left;width:200px;">asd
			
	</div>
	<div style="clear:both;"></div>
</div>
<a class="hidden-city" href="<?php echo site_url('location/get_city'); ?>"></a>
<a class="hidden-district" href="<?php echo site_url('location/get_district'); ?>"></a>